package io.renren.modules.userdata.service.impl;

import org.springframework.stereotype.Service;

import java.util.List;
import java.util.Map;
import com.baomidou.mybatisplus.mapper.EntityWrapper;
import com.baomidou.mybatisplus.plugins.Page;
import com.baomidou.mybatisplus.service.impl.ServiceImpl;
import io.renren.common.utils.PageUtils;
import io.renren.common.utils.Query;

import io.renren.modules.userdata.dao.TLabelDao;
import io.renren.modules.userdata.entity.TLabelEntity;
import io.renren.modules.userdata.service.TLabelService;


@Service("tLabelService")
public class TLabelServiceImpl extends ServiceImpl<TLabelDao, TLabelEntity> implements TLabelService {

    @Override
    public PageUtils queryPage(Map<String, Object> params) {
        Page<TLabelEntity> page = this.selectPage(
                new Query<TLabelEntity>(params).getPage(),
                new EntityWrapper<TLabelEntity>()
        );

        return new PageUtils(page);
    }

    @Override
    public List<Map<String,Object>> listTable(String sql){
        return baseMapper.selectTable(sql);
    }

}
